- var closed = proposal.closed
.inner-container
  - var learnMore = config.learnMoreUrl
  - if (learnMore)
    div.alert.alert-warning.alert-dismissable.system-alert
      button(type="button", class="close", data-dismiss="alert", aria-hidden="true")
      span #{t('proposal-article.article.alert.text')}&nbsp;&nbsp;
      a.alert-link(href=learnMore, target="_blank") #{t('proposal-article.article.alert.learn-more')}


  article.proposal.commentable-container
    //- .meta-information
    //-   a.meta-item.meta-location(href="#") Buenos Aires, Argentina
    //-   small.meta-item.meta-timeago 10 days left

    .entry-tag(style="border-color: #{proposal.tag.color}")

      img(src=tagImages[proposal.tag.image].url, style="fill: white;")

      svg(viewbox='0 0 126 144', version='1.1', xmlns='http://www.w3.org/2000/svg', xmlns:xlink='http://www.w3.org/1999/xlink', xmlns:sketch='http://www.bohemiancoding.com/sketch/ns').hexagon
        title Hexagon
        description Created with Sketch (http://www.bohemiancoding.com/sketch)
        g#Page-1(fill='none', fill-rule='evenodd', sketch:type='MSPage')
          polygon#Polygon-1(d='M63,0 L125.353829,36 L125.353829,108 L63,144 L0.646170928,108 L0.646170928,36 L63,0 Z M63,0', fill='#{proposal.tag.color}', sketch:type='MSShapeGroup', points='63 0 125.353829 36 125.353829 108 63 144 0.646170928 108 0.646170928 36 ')

      div(style="color: #{proposal.tag.color}")= proposal.tag.name

    .meta-information
      p
        i.icon-time
        - if (proposal.closingAt)
          span.time-ago-label= (closed ? t('common.closed') : t('common.close')) + " "
          span.meta-item.meta-timeago.ago(data-time=proposal.closingAt.toString())
        - else
          span.meta-item.meta-timeago= t('proposal-article.unknown-closing-date')

    h1=proposal.mediaTitle
    - if (proposal.author)
      h2.author=t('admin-topics-form.label.author') + ': '
        - if (proposal.authorUrl)
          a(href=proposal.authorUrl, target='_blank')=proposal.author
        - else
          =proposal.author
    h3=proposal.title
    .entry-content
      .clauses
        - var clauses = proposal.clauses
        each clause, i in clauses
          - var classes = ['clause']
          - classes.push(clause.empty ? 'hide' : 'commentable-section')
          !=toHTML(clause, { className: classes, iframeResponsive: true })

    //- Article source
    - if (proposal.source)
      .source
        p
          span.glyphicon.glyphicon-link
          a(target="_blank", href="#{proposal.source}")
           | #{t('proposal-article.view-original-text')}

    //- Article links
    - if (proposal.links && proposal.links.length)
      .links
        h5=t('common.more-information')
        - each link in proposal.links
          p
            span.glyphicon.glyphicon-share
            a(target="_blank", href=link.url, data-topic-link)=link.text

    //- Article participants
    .participants(class=proposal.votable ? '' : 'hide')
      //- Rendered by participants view

    //- Article share links
    - var text = config.tweetText || proposal.mediaTitle
    .share-links
      a(target="_blank", href="http://www.facebook.com/sharer.php?u=#{baseUrl}#{proposal.url}").flaticon.social.facebook
      a(target="_blank", href="http://twitter.com/share?text=#{text}&url=#{baseUrl}#{proposal.url}").flaticon.social.twitter
